2 informal : someone who is likened to the villain in a story: such as
a : a criminal
Designed to keep guns out of the hands of bad guys and children … — Popular Science
b : a military enemy
… a decision that owes more to parochial conflicts within the Armed Forces than to doing the best job of surveilling bad guys.— Stuart F. Brown
c : someone who deserves to be blamed or criticized for causing a bad situation
Meanwhile, it's the environmentalists who are now portrayed as the bad guys, hiring lots of lawyers, consorting with congressmen …— Eric Alterman
d : a person who treats other people harshly or strictly : a person who says or does unpopular things
Parenting isn't just about having beautiful kids and being busy. It's about dealing with problems, and your success as a parent depends on your willingness to be the bad guy. If you aren't willing to be the bad guy, you shouldn't be a parent.— Roy Bragg